<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
</body>
<script>
    function Father(uname,age){
        this.uname=uname,
        this.age=age
    }
    Father.prototype.money=function(){
        console.log('10000');
    }
    function Son(uname,age){
        Father.call(this,uname,age),
        this.score=function(){
         console.log(1223);
        }
    }
    
    Son.prototype=new Father();
    Son.prototype.constructor=Son;
    var son =new Son('小明',12)
    console.log(son.age);
    console.log(son.money());
    console.log(son);
    
</script>
</html>